//
//  DriMessCell.m
//  DefendHealth
//
//  Created by UNOHACHA on 17/2/21.
//  Copyright © 2017年 iMacOne. All rights reserved.
//

#import "DriMessCell.h"



@implementation DriMessCell

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    
    if (self) {
        self.contentView.backgroundColor = kWhiteColor;
        
        UILabel *titLabel = [ReduceCode creatLabelWithFrame:CGRectMake(20, 5, 40, 20) title:@"第一天" titleColor:UIColorFromRGB(0x333333) font:12 textAlignment:NSTextAlignmentLeft];
        [self.contentView addSubview:titLabel];
        
        UILabel *lab2 = [ReduceCode creatLabelWithFrame:CGRectMake(kMaxX(titLabel.frame)+5, 5, 200, 20) title:@"热身5分钟 / 慢跑10分钟" titleColor:UIColorFromRGB(0x333333) font:12 textAlignment:NSTextAlignmentLeft];
        [self.contentView addSubview:lab2];
        
        UILabel *lab3 = [ReduceCode creatLabelWithFrame:CGRectMake(kMaxX(titLabel.frame)+5, kMaxY(lab2.frame), 200, 20) title:@"坡度：无  速度：6.8" titleColor:UIColorFromRGB(0xbebebe) font:12 textAlignment:NSTextAlignmentLeft];
        [self.contentView addSubview:lab3];
        
        [ToolUtil createLine:49 superView:self.contentView lift:20 width:kScreenWidth-40 hight:1 color:K_LineColor];
  
    }
    
    return self;
}

//-(void)oldCellUI{
//    [ToolUtil createLine:0 superView:self.contentView lift:0 width:kScreenWidth-12 hight:0.5 color:kLineColor];
//    
//    UILabel * DAYL = [ReduceCode creatLabelWithFrame:CGRectMake(0,12, 50, 11) title:@"DAY" titleColor:UIColorFromRGB(0x333333) font:11 textAlignment:NSTextAlignmentCenter];
//    [self.contentView addSubview:DAYL];
//    
//    UILabel * DnL = [ReduceCode creatLabelWithFrame:CGRectMake(0,kMaxY(DAYL.frame)+5, 50, 14) title:@"01" titleColor:UIColorFromRGB(0x333333) font:14 textAlignment:NSTextAlignmentCenter];
//    [self.contentView addSubview:DnL];
//    
//    
//    [ToolUtil createLine:12 superView:self.contentView lift:kMaxX(DAYL.frame) width:1 hight:60-24 color:kLineColor];
//    
//    
//    UILabel * titL = [ReduceCode creatLabelWithFrame:CGRectMake(kMaxX(DAYL.frame)+12,12,kScreenWidth-kMaxX(DAYL.frame)-24-27, 14) title:@"跑步第一天 克服你的小懒惰" titleColor:UIColorFromRGB(0x333333) font:14 textAlignment:NSTextAlignmentLeft];
//    [self.contentView addSubview:titL];
//    
//    UILabel * mesL = [ReduceCode creatLabelWithFrame:CGRectMake(kMaxX(DAYL.frame)+12,kMaxY(DAYL.frame)+12, titL.width, 12) title:@"2106米 25分钟 消耗=" titleColor:UIColorFromRGB(0x666666) font:12 textAlignment:NSTextAlignmentLeft];
//    [self.contentView addSubview:mesL];
//    
//    UIImageView * weather = [ReduceCode creatImageVeiwWithFrame:CGRectMake(kScreenWidth-17, (60-14)/2, 7, 11) imageName:@"point" isCorner:NO];
//    [self.contentView addSubview:weather];
//}
//+(NSString *)cellReuseID:(NSInteger)section with:(NSString *)timer{
//    switch (section) {
//        case 0:
//            if (![timer isEqualToString:@""]) {
//                return @"StartTimerCell";
//            }else{
//                return @"RemindCell";
//            }
//            break;
//        case 1:
//            return @"DriMessCell";
//            break;
//            
//        default:
//            break;
//    }
//    return @"";
//   
//}

+(NSString *)cellReuseID:(NSInteger)section with:(NSInteger)row
{
    switch (section) {
        case 0:
        {
            switch (row) {
                case 0:
                    return @"RemindCell";
                    break;
                case 1:
                    return @"StartTimerCell";
                    break;
                default:
                    break;
            }
        }
            break;
        case 1:
            return @"DriMessCell";
            break;
            
        default:
            break;
    }
    return @"";
}
@end
